import codecs

zh_file = codecs.open('dev.zh', 'w', encoding='utf-8')
en_file = codecs.open('dev.en', 'w', encoding='utf-8')
with codecs.open('./raw/Niu.dev.txt', encoding='utf-8') as f:
    while(True):
        zh_line = f.readline().strip()
        if zh_line == '':
            break
        f.readline()
        en_line = f.readline().strip()
        zh_file.write(zh_line + '\n')
        en_file.write(en_line + '\n')
zh_file.close()
en_file.close()
